import java.util.regex.Pattern;

public abstract class Messages {
	
	/** Message to indicate that the connection should be severed. */
	public static final Pattern TERMINATION = Pattern.compile("BYE");
	
	/** Message sent to the client by the server to indicate that the connection has been established. */
	public static final Pattern WELCOME = Pattern.compile("HELLO");
	
    /** Message sent by the client to the server to indicate that a simulation has completed. The first parameter is the trace location (top, mid, bot), the second parameter is the value for Wtop1 and the last value is the simulated impedance.*/
    public static final Pattern SIM_COMPLETE = Pattern.compile("SIMCOMP (\\w+?) (\\d+\\.\\d+) (\\d+\\.\\d+)");
    
    public static final Pattern SIM_START = Pattern.compile("SIMSTART");
    
    public static final Pattern SIM_END = Pattern.compile("SIMEND");
    
    /** Message sent between the client and server to indicate that the last message was improperly formatted. */
    public static final Pattern SYN_ERROR = Pattern.compile("SYNERROR (.*)");
    
    /** Message sent by the client to the server to indicate that an error with the simulations has occurred. The first argument is a priority level with 1 being highest priority and 5 being lowest. */
    public static final Pattern ERROR = Pattern.compile("ERROR (\\d.+) (.*)");
    
}
